{% extends 'teachers/base.html' %}
{% block teachers_index %}
    {% load static %}

    <div class="col-md-6 offset-3" style="border: 1px solid black;border-radius: 15px;margin-top: 30px">
        <div style="margin: 30px 30px 30px 30px">
            <h3 style="margin-top: 30px">&emsp;&emsp;添加课程</h3>
            <hr>
            <form action="" method="post" enctype="multipart/form-data">
                {% csrf_token %}
                <div class="row mb-3">
                    <label for="inputEmail3" class="col-sm-2 col-form-label">课程名</label>
                    <div class="col-sm-10">
                        <input name="name" required type="text" class="form-control" id="inputEmail3">
                    </div>
                </div>
                <div class="row mb-3">
                    <label for="inputPassword3" class="col-sm-2 col-form-label">图片</label>
                    <div class="col-sm-10">
                        <input required type="file" class="form-control" id="inputPassword3" name="photo">
                    </div>
                </div>
                <div class="row mb-3">
                    <label for="inputPassword3" class="col-sm-2 col-form-label">课程简介</label>
                    <div class="col-sm-10">
                        <textarea name="introduction" required class="form-control" id="exampleFormControlTextarea1"
                                  rows="3"></textarea>
                    </div>
                </div>


                <fieldset class="row mb-3">
                    <legend class="col-form-label col-sm-2 pt-0">课程类型</legend>
                    <div class="col-sm-10">
                        <select name="type" required class="form-select" aria-label="Default select example">
                            <option selected>选择课程类型</option>
                            <option value="1">加工学</option>

                        </select>

                    </div>
                </fieldset>

                <br>
                <button type="submit" class="btn btn-primary offset-9 w-25">保存</button>
            </form>
        </div>
    </div>
{% endblock %}